package com.ruoyi.system.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Length;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;

/**
 * 首页Banner轮播图配置DTO
 */
@Data
@ApiModel("首页Banner轮播图配置DTO")
public class HomeBannerDTO {

    @ApiModelProperty(value = "主键ID", hidden = true)
    private Long id;

    @ApiModelProperty(value = "文案标题", required = true)
    @NotBlank(message = "文案标题不能为空")
    @Length(max = 15, message = "文案标题最多15个汉字")
    private String title;

    @ApiModelProperty(value = "Banner图片URL", required = true)
    @NotBlank(message = "Banner图片不能为空")
    private String imageUrl;

    @ApiModelProperty(value = "跳转链接")
    private String linkUrl;

    @ApiModelProperty(value = "排序序号")
    private Integer sort;

    @ApiModelProperty(value = "状态：0-下线，1-上线", required = true)
    @NotNull(message = "状态不能为空")
    private Integer status;
}
